package com.pzh.guli.service.edu.controller;

import com.pzh.guli.service.base.result.Result;
import org.springframework.web.bind.annotation.*;


@RestController
@RequestMapping("/user")
public class LoginController {
    @PostMapping("login")
    public Result login(){
        return Result.ok().data("token","admin");
    }
    @GetMapping("info")
    public Result info(){
        return Result.ok().data("name","xzh")
                .data("avatar","https://guli-file-2023.oss-cn-hangzhou.aliyuncs.com/avatar/2022/05/21/9988991a-2b66-4637-b773-5686a34c2485.png")
                .data("roles","[admin]");
    }
    @PostMapping("logout")
    public Result logout(){
        return Result.ok();
    }
}
